<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="utf-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <meta name="viewport" content="width=device-width, height=device-height, initial-scale=1, user-scalable=no">
  <meta name="description" content="API docs for the HttpServer class from the dart:io library, for the Dart programming language.">
  <title>HttpServer class - dart:io library - Dart API</title>
  <!-- required because all the links are pseudo-absolute -->
  <base href="..">

  <link href="https://fonts.googleapis.com/css?family=Source+Code+Pro:500,400i,400,300|Source+Sans+Pro:400,300,700" rel="stylesheet">
  <link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">
  <link rel="stylesheet" href="static-assets/github.css">
  <link rel="stylesheet" href="static-assets/styles.css">
  <link rel="icon" href="static-assets/favicon.png">
  
</head>

<body>

<div id="overlay-under-drawer"></div>

<header id="title">
  <button id="sidenav-left-toggle" type="button">&nbsp;</button>
  <ol class="breadcrumbs gt-separated dark hidden-xs">
    <li><a href="index.html">shake</a></li>
    <li><a href="dart-io/dart-io-library.html">dart:io</a></li>
    <li class="self-crumb">HttpServer abstract class</li>
  </ol>
  <div class="self-name">HttpServer</div>
  <form class="search navbar-right" role="search">
    <input type="text" id="search-box" autocomplete="off" disabled class="form-control typeahead" placeholder="Loading search...">
  </form>
</header>

<main>

  <div id="dartdoc-sidebar-left" class="col-xs-6 col-sm-3 col-md-2 sidebar sidebar-offcanvas-left">
    <header id="header-search-sidebar" class="hidden-l">
      <form class="search-sidebar" role="search">
        <input type="text" id="search-sidebar" autocomplete="off" disabled class="form-control typeahead" placeholder="Loading search...">
      </form>
    </header>
    
    <ol class="breadcrumbs gt-separated dark hidden-l" id="sidebar-nav">
      <li><a href="index.html">shake</a></li>
      <li><a href="dart-io/dart-io-library.html">dart:io</a></li>
      <li class="self-crumb">HttpServer abstract class</li>
    </ol>
    
    <h5>dart:io library</h5>
    <ol>
      <li class="section-title"><a href="dart-io/dart-io-library.html#classes">Classes</a></li>
      <li><a href="dart-io/BytesBuilder-class.html">BytesBuilder</a></li>
      <li><a href="dart-io/CompressionOptions-class.html">CompressionOptions</a></li>
      <li><a href="dart-io/ConnectionTask-class.html">ConnectionTask</a></li>
      <li><a href="dart-io/ContentType-class.html">ContentType</a></li>
      <li><a href="dart-io/Cookie-class.html">Cookie</a></li>
      <li><a href="dart-io/Datagram-class.html">Datagram</a></li>
      <li><a href="dart-io/DetachedSocket-class.html">DetachedSocket</a></li>
      <li><a href="dart-io/Directory-class.html">Directory</a></li>
      <li><a href="dart-io/File-class.html">File</a></li>
      <li><a href="dart-io/FileLock-class.html">FileLock</a></li>
      <li><a href="dart-io/FileMode-class.html">FileMode</a></li>
      <li><a href="dart-io/FileStat-class.html">FileStat</a></li>
      <li><a href="dart-io/FileSystemCreateEvent-class.html">FileSystemCreateEvent</a></li>
      <li><a href="dart-io/FileSystemDeleteEvent-class.html">FileSystemDeleteEvent</a></li>
      <li><a href="dart-io/FileSystemEntity-class.html">FileSystemEntity</a></li>
      <li><a href="dart-io/FileSystemEntityType-class.html">FileSystemEntityType</a></li>
      <li><a href="dart-io/FileSystemEvent-class.html">FileSystemEvent</a></li>
      <li><a href="dart-io/FileSystemModifyEvent-class.html">FileSystemModifyEvent</a></li>
      <li><a href="dart-io/FileSystemMoveEvent-class.html">FileSystemMoveEvent</a></li>
      <li><a href="dart-io/GZipCodec-class.html">GZipCodec</a></li>
      <li><a href="dart-io/HeaderValue-class.html">HeaderValue</a></li>
      <li><a href="dart-io/HttpClient-class.html">HttpClient</a></li>
      <li><a href="dart-io/HttpClientBasicCredentials-class.html">HttpClientBasicCredentials</a></li>
      <li><a href="dart-io/HttpClientCredentials-class.html">HttpClientCredentials</a></li>
      <li><a href="dart-io/HttpClientDigestCredentials-class.html">HttpClientDigestCredentials</a></li>
      <li><a href="dart-io/HttpClientRequest-class.html">HttpClientRequest</a></li>
      <li><a href="dart-io/HttpClientResponse-class.html">HttpClientResponse</a></li>
      <li><a href="dart-io/HttpConnectionInfo-class.html">HttpConnectionInfo</a></li>
      <li><a href="dart-io/HttpConnectionsInfo-class.html">HttpConnectionsInfo</a></li>
      <li><a href="dart-io/HttpDate-class.html">HttpDate</a></li>
      <li><a href="dart-io/HttpHeaders-class.html">HttpHeaders</a></li>
      <li><a href="dart-io/HttpOverrides-class.html">HttpOverrides</a></li>
      <li><a href="dart-io/HttpRequest-class.html">HttpRequest</a></li>
      <li><a href="dart-io/HttpResponse-class.html">HttpResponse</a></li>
      <li><a href="dart-io/HttpServer-class.html">HttpServer</a></li>
      <li><a href="dart-io/HttpSession-class.html">HttpSession</a></li>
      <li><a href="dart-io/HttpStatus-class.html">HttpStatus</a></li>
      <li><a href="dart-io/InternetAddress-class.html">InternetAddress</a></li>
      <li><a href="dart-io/InternetAddressType-class.html">InternetAddressType</a></li>
      <li><a href="dart-io/IOOverrides-class.html">IOOverrides</a></li>
      <li><a href="dart-io/IOSink-class.html">IOSink</a></li>
      <li><a href="dart-io/Link-class.html">Link</a></li>
      <li><a href="dart-io/NetworkInterface-class.html">NetworkInterface</a></li>
      <li><a href="dart-io/OSError-class.html">OSError</a></li>
      <li><a href="dart-io/Platform-class.html">Platform</a></li>
      <li><a href="dart-io/Process-class.html">Process</a></li>
      <li><a href="dart-io/ProcessInfo-class.html">ProcessInfo</a></li>
      <li><a href="dart-io/ProcessResult-class.html">ProcessResult</a></li>
      <li><a href="dart-io/ProcessSignal-class.html">ProcessSignal</a></li>
      <li><a href="dart-io/ProcessStartMode-class.html">ProcessStartMode</a></li>
      <li><a href="dart-io/RandomAccessFile-class.html">RandomAccessFile</a></li>
      <li><a href="dart-io/RawDatagramSocket-class.html">RawDatagramSocket</a></li>
      <li><a href="dart-io/RawSecureServerSocket-class.html">RawSecureServerSocket</a></li>
      <li><a href="dart-io/RawSecureSocket-class.html">RawSecureSocket</a></li>
      <li><a href="dart-io/RawServerSocket-class.html">RawServerSocket</a></li>
      <li><a href="dart-io/RawSocket-class.html">RawSocket</a></li>
      <li><a href="dart-io/RawSocketEvent-class.html">RawSocketEvent</a></li>
      <li><a href="dart-io/RawSocketOption-class.html">RawSocketOption</a></li>
      <li><a href="dart-io/RawSynchronousSocket-class.html">RawSynchronousSocket</a></li>
      <li><a href="dart-io/RawZLibFilter-class.html">RawZLibFilter</a></li>
      <li><a href="dart-io/RedirectInfo-class.html">RedirectInfo</a></li>
      <li><a href="dart-io/SecureServerSocket-class.html">SecureServerSocket</a></li>
      <li><a href="dart-io/SecureSocket-class.html">SecureSocket</a></li>
      <li><a href="dart-io/SecurityContext-class.html">SecurityContext</a></li>
      <li><a href="dart-io/ServerSocket-class.html">ServerSocket</a></li>
      <li><a href="dart-io/Socket-class.html">Socket</a></li>
      <li><a href="dart-io/SocketDirection-class.html">SocketDirection</a></li>
      <li><a href="dart-io/SocketOption-class.html">SocketOption</a></li>
      <li><a href="dart-io/Stdin-class.html">Stdin</a></li>
      <li><a href="dart-io/StdioType-class.html">StdioType</a></li>
      <li><a href="dart-io/Stdout-class.html">Stdout</a></li>
      <li><a href="dart-io/SystemEncoding-class.html">SystemEncoding</a></li>
      <li><a href="dart-io/WebSocket-class.html">WebSocket</a></li>
      <li><a href="dart-io/WebSocketStatus-class.html">WebSocketStatus</a></li>
      <li><a href="dart-io/WebSocketTransformer-class.html">WebSocketTransformer</a></li>
      <li><a href="dart-io/X509Certificate-class.html">X509Certificate</a></li>
      <li><a href="dart-io/ZLibCodec-class.html">ZLibCodec</a></li>
      <li><a href="dart-io/ZLibDecoder-class.html">ZLibDecoder</a></li>
      <li><a href="dart-io/ZLibEncoder-class.html">ZLibEncoder</a></li>
      <li><a href="dart-io/ZLibOption-class.html">ZLibOption</a></li>
    
    
      <li class="section-title"><a href="dart-io/dart-io-library.html#constants">Constants</a></li>
      <li><a class="deprecated" href="dart-io/APPEND-constant.html">APPEND</a></li>
      <li><a class="deprecated" href="dart-io/GZIP-constant.html">GZIP</a></li>
      <li><a href="dart-io/gzip-constant.html">gzip</a></li>
      <li><a class="deprecated" href="dart-io/READ-constant.html">READ</a></li>
      <li><a class="deprecated" href="dart-io/SYSTEM_ENCODING-constant.html">SYSTEM_ENCODING</a></li>
      <li><a href="dart-io/systemEncoding-constant.html">systemEncoding</a></li>
      <li><a class="deprecated" href="dart-io/WRITE-constant.html">WRITE</a></li>
      <li><a class="deprecated" href="dart-io/WRITE_ONLY-constant.html">WRITE_ONLY</a></li>
      <li><a class="deprecated" href="dart-io/WRITE_ONLY_APPEND-constant.html">WRITE_ONLY_APPEND</a></li>
      <li><a class="deprecated" href="dart-io/ZLIB-constant.html">ZLIB</a></li>
      <li><a href="dart-io/zlib-constant.html">zlib</a></li>
    
      <li class="section-title"><a href="dart-io/dart-io-library.html#properties">Properties</a></li>
      <li><a href="dart-io/exitCode.html">exitCode</a></li>
      <li><a href="dart-io/pid.html">pid</a></li>
      <li><a href="dart-io/stderr.html">stderr</a></li>
      <li><a href="dart-io/stdin.html">stdin</a></li>
      <li><a href="dart-io/stdout.html">stdout</a></li>
    
      <li class="section-title"><a href="dart-io/dart-io-library.html#functions">Functions</a></li>
      <li><a href="dart-io/exit.html">exit</a></li>
      <li><a href="dart-io/sleep.html">sleep</a></li>
      <li><a href="dart-io/stdioType.html">stdioType</a></li>
    
    
      <li class="section-title"><a href="dart-io/dart-io-library.html#typedefs">Typedefs</a></li>
      <li><a href="dart-io/BadCertificateCallback.html">BadCertificateCallback</a></li>
    
      <li class="section-title"><a href="dart-io/dart-io-library.html#exceptions">Exceptions</a></li>
      <li><a href="dart-io/CertificateException-class.html">CertificateException</a></li>
      <li><a href="dart-io/FileSystemException-class.html">FileSystemException</a></li>
      <li><a href="dart-io/HandshakeException-class.html">HandshakeException</a></li>
      <li><a href="dart-io/HttpException-class.html">HttpException</a></li>
      <li><a href="dart-io/IOException-class.html">IOException</a></li>
      <li><a href="dart-io/ProcessException-class.html">ProcessException</a></li>
      <li><a href="dart-io/RedirectException-class.html">RedirectException</a></li>
      <li><a href="dart-io/SignalException-class.html">SignalException</a></li>
      <li><a href="dart-io/SocketException-class.html">SocketException</a></li>
      <li><a href="dart-io/StdinException-class.html">StdinException</a></li>
      <li><a href="dart-io/StdoutException-class.html">StdoutException</a></li>
      <li><a href="dart-io/TlsException-class.html">TlsException</a></li>
      <li><a href="dart-io/WebSocketException-class.html">WebSocketException</a></li>
    </ol>
  </div>

  <div id="dartdoc-main-content" class="col-xs-12 col-sm-9 col-md-8 main-content">
      <div><h1>HttpServer class </h1></div>

    <section class="desc markdown">
      <p>A server that delivers content, such as web pages, using the HTTP protocol.</p>
<p>The HttpServer is a <a href="dart-async/Stream-class.html">Stream</a> that provides <a href="dart-io/HttpRequest-class.html">HttpRequest</a> objects. Each
HttpRequest has an associated <a href="dart-io/HttpResponse-class.html">HttpResponse</a> object.
The server responds to a request by writing to that HttpResponse object.
The following example shows how to bind an HttpServer to an IPv6
<a href="dart-io/InternetAddress-class.html">InternetAddress</a> on port 80 (the standard port for HTTP servers)
and how to listen for requests.
Port 80 is the default HTTP port. However, on most systems accessing
this requires super-user privileges. For local testing consider
using a non-reserved port (1024 and above).</p>
<pre class="language-dart"><code>import 'dart:io';

main() {
  HttpServer
      .bind(InternetAddress.anyIPv6, 80)
      .then((server) {
        server.listen((HttpRequest request) {
          request.response.write('Hello, world!');
          request.response.close();
        });
      });
}
</code></pre>
<p>Incomplete requests, in which all or part of the header is missing, are
ignored, and no exceptions or HttpRequest objects are generated for them.
Likewise, when writing to an HttpResponse, any <a href="dart-io/Socket-class.html">Socket</a> exceptions are
ignored and any future writes are ignored.</p>
<p>The HttpRequest exposes the request headers and provides the request body,
if it exists, as a Stream of data. If the body is unread, it is drained
when the server writes to the HttpResponse or closes it.</p>
<h2 id="bind-with-a-secure-https-connection">Bind with a secure HTTPS connection</h2>
<p>Use <a href="dart-io/HttpServer/bindSecure.html">bindSecure</a> to create an HTTPS server.</p>
<p>The server presents a certificate to the client. The certificate
chain and the private key are set in the <a href="dart-io/SecurityContext-class.html">SecurityContext</a>
object that is passed to <a href="dart-io/HttpServer/bindSecure.html">bindSecure</a>.</p>
<pre class="language-dart"><code>import 'dart:io';
import "dart:isolate";

main() {
  SecurityContext context = new SecurityContext();
  var chain =
      Platform.script.resolve('certificates/server_chain.pem')
      .toFilePath();
  var key =
      Platform.script.resolve('certificates/server_key.pem')
      .toFilePath();
  context.useCertificateChain(chain);
  context.usePrivateKey(key, password: 'dartdart');

  HttpServer
      .bindSecure(InternetAddress.anyIPv6,
                  443,
                  context)
      .then((server) {
        server.listen((HttpRequest request) {
          request.response.write('Hello, world!');
          request.response.close();
        });
      });
}
</code></pre>
<p> The certificates and keys are PEM files, which can be created and
 managed with the tools in OpenSSL.</p>
<h2 id="connect-to-a-server-socket">Connect to a server socket</h2>
<p>You can use the <a href="dart-io/HttpServer/HttpServer.listenOn.html">listenOn</a> constructor to attach an HTTP server to
a <a href="dart-io/ServerSocket-class.html">ServerSocket</a>.</p>
<pre class="language-dart"><code>import 'dart:io';

main() {
  ServerSocket.bind(InternetAddress.anyIPv6, 80)
    .then((serverSocket) {
      HttpServer httpserver = new HttpServer.listenOn(serverSocket);
      serverSocket.listen((Socket socket) {
        socket.write('Hello, client.');
      });
    });
}
</code></pre>
<h2 id="other-resources">Other resources</h2><ul><li>
<p>HttpServer is a Stream. Refer to the <a href="dart-async/Stream-class.html">Stream</a> class for information
about the streaming qualities of an HttpServer.
Pausing the subscription of the stream, pauses at the OS level.</p></li><li>
<p>The <a href="https://pub.dartlang.org/packages/shelf">shelf</a>
package on pub.dartlang.org contains a set of high-level classes that,
together with this class, makes it easy to provide content through HTTP
servers.</p></li></ul>
    </section>
    
    <section>
      <dl class="dl-horizontal">

        <dt>Implemented types</dt>
        <dd>
          <ul class="comma-separated clazz-relationships">
            <li><a href="dart-async/Stream-class.html">Stream</a><span class="signature">&lt;<wbr><span class="type-parameter"><a href="dart-io/HttpRequest-class.html">HttpRequest</a></span>&gt;</span></li>
          </ul>
        </dd>



      </dl>
    </section>

    <section class="summary offset-anchor" id="constructors">
      <h2>Constructors</h2>

      <dl class="constructor-summary-list">
        <dt id="HttpServer.listenOn" class="callable">
          <span class="name"><a href="dart-io/HttpServer/HttpServer.listenOn.html">HttpServer.listenOn</a></span><span class="signature">(<span class="parameter" id="listenOn-param-serverSocket"><span class="type-annotation"><a href="dart-io/ServerSocket-class.html">ServerSocket</a></span> <span class="parameter-name">serverSocket</span></span>)</span>
        </dt>
        <dd>
          Attaches the HTTP server to an existing <a href="dart-io/ServerSocket-class.html">ServerSocket</a>. When the
<a href="dart-io/HttpServer-class.html">HttpServer</a> is closed, the <a href="dart-io/HttpServer-class.html">HttpServer</a> will just detach itself,
closing current connections but not closing <code>serverSocket</code>.
          <div class="constructor-modifier features">factory</div>
        </dd>
      </dl>
    </section>

    <section class="summary offset-anchor" id="instance-properties">
      <h2>Properties</h2>

      <dl class="properties">
        <dt id="address" class="property">
          <span class="name"><a href="dart-io/HttpServer/address.html">address</a></span>
          <span class="signature">&#8594; <a href="dart-io/InternetAddress-class.html">InternetAddress</a></span>         
        </dt>
        <dd>
          Returns the address that the server is listening on. This can be
used to get the actual address used, when the address is fetched by
a lookup from a hostname.
                  <div class="features">read-only</div>
</dd>
        <dt id="autoCompress" class="property">
          <span class="name"><a href="dart-io/HttpServer/autoCompress.html">autoCompress</a></span>
          <span class="signature">&#8596; <a href="dart-core/bool-class.html">bool</a></span>         
        </dt>
        <dd>
          Whether the <a href="dart-io/HttpServer-class.html">HttpServer</a> should compress the content, if possible. <a href="dart-io/HttpServer/autoCompress.html">[...]</a>
                  <div class="features">read / write</div>
</dd>
        <dt id="defaultResponseHeaders" class="property">
          <span class="name"><a href="dart-io/HttpServer/defaultResponseHeaders.html">defaultResponseHeaders</a></span>
          <span class="signature">&#8594; <a href="dart-io/HttpHeaders-class.html">HttpHeaders</a></span>         
        </dt>
        <dd>
          Default set of headers added to all response objects. <a href="dart-io/HttpServer/defaultResponseHeaders.html">[...]</a>
                  <div class="features">read-only</div>
</dd>
        <dt id="idleTimeout" class="property">
          <span class="name"><a href="dart-io/HttpServer/idleTimeout.html">idleTimeout</a></span>
          <span class="signature">&#8596; <a href="dart-core/Duration-class.html">Duration</a></span>         
        </dt>
        <dd>
          Gets or sets the timeout used for idle keep-alive connections. If no
further request is seen within <a href="dart-io/HttpServer/idleTimeout.html">idleTimeout</a> after the previous request was
completed, the connection is dropped. <a href="dart-io/HttpServer/idleTimeout.html">[...]</a>
                  <div class="features">read / write</div>
</dd>
        <dt id="port" class="property">
          <span class="name"><a href="dart-io/HttpServer/port.html">port</a></span>
          <span class="signature">&#8594; <a href="dart-core/int-class.html">int</a></span>         
        </dt>
        <dd>
          Returns the port that the server is listening on. This can be
used to get the actual port used when a value of 0 for <code>port</code> is
specified in the <a href="dart-io/HttpServer/bind.html">bind</a> or <a href="dart-io/HttpServer/bindSecure.html">bindSecure</a> call.
                  <div class="features">read-only</div>
</dd>
        <dt id="serverHeader" class="property">
          <span class="name"><a href="dart-io/HttpServer/serverHeader.html">serverHeader</a></span>
          <span class="signature">&#8596; <a href="dart-core/String-class.html">String</a></span>         
        </dt>
        <dd>
          Gets and sets the default value of the <code>Server</code> header for all responses
generated by this <a href="dart-io/HttpServer-class.html">HttpServer</a>. <a href="dart-io/HttpServer/serverHeader.html">[...]</a>
                  <div class="features">read / write</div>
</dd>
        <dt id="sessionTimeout" class="property">
          <span class="name"><a href="dart-io/HttpServer/sessionTimeout.html">sessionTimeout</a></span>
          <span class="signature">&#8592; <span class="parameter" id="sessionTimeout=-param-timeout"><span class="type-annotation"><a href="dart-core/int-class.html">int</a></span></span></span>         
        </dt>
        <dd>
          Sets the timeout, in seconds, for sessions of this <a href="dart-io/HttpServer-class.html">HttpServer</a>.
The default timeout is 20 minutes.
                  <div class="features">write-only</div>
</dd>
        <dt id="first" class="property inherited">
          <span class="name"><a href="dart-async/Stream/first.html">first</a></span>
          <span class="signature">&#8594; <a href="dart-async/Future-class.html">Future</a><span class="signature">&lt;<wbr><span class="type-parameter"><a href="dart-io/HttpRequest-class.html">HttpRequest</a></span>&gt;</span></span>         
        </dt>
        <dd class="inherited">
          The first element of this stream. <a href="dart-async/Stream/first.html">[...]</a>
                  <div class="features">read-only, inherited</div>
</dd>
        <dt id="hashCode" class="property inherited">
          <span class="name"><a href="dart-core/Object/hashCode.html">hashCode</a></span>
          <span class="signature">&#8594; <a href="dart-core/int-class.html">int</a></span>         
        </dt>
        <dd class="inherited">
          The hash code for this object. <a href="dart-core/Object/hashCode.html">[...]</a>
                  <div class="features">read-only, inherited</div>
</dd>
        <dt id="isBroadcast" class="property inherited">
          <span class="name"><a href="dart-async/Stream/isBroadcast.html">isBroadcast</a></span>
          <span class="signature">&#8594; <a href="dart-core/bool-class.html">bool</a></span>         
        </dt>
        <dd class="inherited">
          Whether this stream is a broadcast stream.
                  <div class="features">read-only, inherited</div>
</dd>
        <dt id="isEmpty" class="property inherited">
          <span class="name"><a href="dart-async/Stream/isEmpty.html">isEmpty</a></span>
          <span class="signature">&#8594; <a href="dart-async/Future-class.html">Future</a><span class="signature">&lt;<wbr><span class="type-parameter"><a href="dart-core/bool-class.html">bool</a></span>&gt;</span></span>         
        </dt>
        <dd class="inherited">
          Whether this stream contains any elements. <a href="dart-async/Stream/isEmpty.html">[...]</a>
                  <div class="features">read-only, inherited</div>
</dd>
        <dt id="last" class="property inherited">
          <span class="name"><a href="dart-async/Stream/last.html">last</a></span>
          <span class="signature">&#8594; <a href="dart-async/Future-class.html">Future</a><span class="signature">&lt;<wbr><span class="type-parameter"><a href="dart-io/HttpRequest-class.html">HttpRequest</a></span>&gt;</span></span>         
        </dt>
        <dd class="inherited">
          The last element of this stream. <a href="dart-async/Stream/last.html">[...]</a>
                  <div class="features">read-only, inherited</div>
</dd>
        <dt id="length" class="property inherited">
          <span class="name"><a href="dart-async/Stream/length.html">length</a></span>
          <span class="signature">&#8594; <a href="dart-async/Future-class.html">Future</a><span class="signature">&lt;<wbr><span class="type-parameter"><a href="dart-core/int-class.html">int</a></span>&gt;</span></span>         
        </dt>
        <dd class="inherited">
          The number of elements in this stream. <a href="dart-async/Stream/length.html">[...]</a>
                  <div class="features">read-only, inherited</div>
</dd>
        <dt id="runtimeType" class="property inherited">
          <span class="name"><a href="dart-core/Object/runtimeType.html">runtimeType</a></span>
          <span class="signature">&#8594; <a href="dart-core/Type-class.html">Type</a></span>         
        </dt>
        <dd class="inherited">
          A representation of the runtime type of the object.
                  <div class="features">read-only, inherited</div>
</dd>
        <dt id="single" class="property inherited">
          <span class="name"><a href="dart-async/Stream/single.html">single</a></span>
          <span class="signature">&#8594; <a href="dart-async/Future-class.html">Future</a><span class="signature">&lt;<wbr><span class="type-parameter"><a href="dart-io/HttpRequest-class.html">HttpRequest</a></span>&gt;</span></span>         
        </dt>
        <dd class="inherited">
          The single element of this stream. <a href="dart-async/Stream/single.html">[...]</a>
                  <div class="features">read-only, inherited</div>
</dd>
      </dl>
    </section>

    <section class="summary offset-anchor" id="instance-methods">
      <h2>Methods</h2>
      <dl class="callables">
        <dt id="close" class="callable">
          <span class="name"><a href="dart-io/HttpServer/close.html">close</a></span><span class="signature">(<wbr>{<span class="parameter" id="close-param-force"><span class="type-annotation"><a href="dart-core/bool-class.html">bool</a></span> <span class="parameter-name">force</span>: <span class="default-value">false</span></span> })
            <span class="returntype parameter">&#8594; <a href="dart-async/Future-class.html">Future</a></span>
          </span>
                  </dt>
        <dd>
          Permanently stops this <a href="dart-io/HttpServer-class.html">HttpServer</a> from listening for new
connections.  This closes the <a href="dart-async/Stream-class.html">Stream</a> of <a href="dart-io/HttpRequest-class.html">HttpRequest</a>s with a
done event. The returned future completes when the server is
stopped. For a server started using <a href="dart-io/HttpServer/bind.html">bind</a> or <a href="dart-io/HttpServer/bindSecure.html">bindSecure</a> this
means that the port listened on no longer in use. <a href="dart-io/HttpServer/close.html">[...]</a>
                  
</dd>
        <dt id="connectionsInfo" class="callable">
          <span class="name"><a href="dart-io/HttpServer/connectionsInfo.html">connectionsInfo</a></span><span class="signature">(<wbr>)
            <span class="returntype parameter">&#8594; <a href="dart-io/HttpConnectionsInfo-class.html">HttpConnectionsInfo</a></span>
          </span>
                  </dt>
        <dd>
          Returns an <a href="dart-io/HttpConnectionsInfo-class.html">HttpConnectionsInfo</a> object summarizing the number of
current connections handled by the server.
                  
</dd>
        <dt id="any" class="callable inherited">
          <span class="name"><a href="dart-async/Stream/any.html">any</a></span><span class="signature">(<wbr><span class="parameter" id="any-param-test"><span class="type-annotation"><a href="dart-core/bool-class.html">bool</a></span> <span class="parameter-name">test</span>(<span class="parameter" id="test-param-element"><span class="type-annotation">T</span> <span class="parameter-name">element</span></span>)</span>)
            <span class="returntype parameter">&#8594; <a href="dart-async/Future-class.html">Future</a><span class="signature">&lt;<wbr><span class="type-parameter"><a href="dart-core/bool-class.html">bool</a></span>&gt;</span></span>
          </span>
                  </dt>
        <dd class="inherited">
          Checks whether <code>test</code> accepts any element provided by this stream. <a href="dart-async/Stream/any.html">[...]</a>
                  <div class="features">inherited</div>
</dd>
        <dt id="asBroadcastStream" class="callable inherited">
          <span class="name"><a href="dart-async/Stream/asBroadcastStream.html">asBroadcastStream</a></span><span class="signature">(<wbr>{<span class="parameter" id="asBroadcastStream-param-onListen"><span class="type-annotation">void</span> <span class="parameter-name">onListen</span>(<span class="parameter" id="onListen-param-subscription"><span class="type-annotation"><a href="dart-async/StreamSubscription-class.html">StreamSubscription</a><span class="signature">&lt;<wbr><span class="type-parameter">T</span>&gt;</span></span> <span class="parameter-name">subscription</span></span>), </span> <span class="parameter" id="asBroadcastStream-param-onCancel"><span class="type-annotation">void</span> <span class="parameter-name">onCancel</span>(<span class="parameter" id="onCancel-param-subscription"><span class="type-annotation"><a href="dart-async/StreamSubscription-class.html">StreamSubscription</a><span class="signature">&lt;<wbr><span class="type-parameter">T</span>&gt;</span></span> <span class="parameter-name">subscription</span></span>)</span> })
            <span class="returntype parameter">&#8594; <a href="dart-async/Stream-class.html">Stream</a><span class="signature">&lt;<wbr><span class="type-parameter"><a href="dart-io/HttpRequest-class.html">HttpRequest</a></span>&gt;</span></span>
          </span>
                  </dt>
        <dd class="inherited">
          Returns a multi-subscription stream that produces the same events as this. <a href="dart-async/Stream/asBroadcastStream.html">[...]</a>
                  <div class="features">inherited</div>
</dd>
        <dt id="asyncExpand" class="callable inherited">
          <span class="name"><a href="dart-async/Stream/asyncExpand.html">asyncExpand</a></span><span class="signature">&lt;<wbr><span class="type-parameter">E</span>&gt;</span><span class="signature">(<wbr><span class="parameter" id="asyncExpand-param-convert"><span class="type-annotation"><a href="dart-async/Stream-class.html">Stream</a><span class="signature">&lt;<wbr><span class="type-parameter">E</span>&gt;</span></span> <span class="parameter-name">convert</span>(<span class="parameter" id="convert-param-event"><span class="type-annotation">T</span> <span class="parameter-name">event</span></span>)</span>)
            <span class="returntype parameter">&#8594; <a href="dart-async/Stream-class.html">Stream</a><span class="signature">&lt;<wbr><span class="type-parameter">E</span>&gt;</span></span>
          </span>
                  </dt>
        <dd class="inherited">
          Transforms each element into a sequence of asynchronous events. <a href="dart-async/Stream/asyncExpand.html">[...]</a>
                  <div class="features">inherited</div>
</dd>
        <dt id="asyncMap" class="callable inherited">
          <span class="name"><a href="dart-async/Stream/asyncMap.html">asyncMap</a></span><span class="signature">&lt;<wbr><span class="type-parameter">E</span>&gt;</span><span class="signature">(<wbr><span class="parameter" id="asyncMap-param-convert"><span class="type-annotation"><a href="dart-async/FutureOr-class.html">FutureOr</a><span class="signature">&lt;<wbr><span class="type-parameter">E</span>&gt;</span></span> <span class="parameter-name">convert</span>(<span class="parameter" id="convert-param-event"><span class="type-annotation">T</span> <span class="parameter-name">event</span></span>)</span>)
            <span class="returntype parameter">&#8594; <a href="dart-async/Stream-class.html">Stream</a><span class="signature">&lt;<wbr><span class="type-parameter">E</span>&gt;</span></span>
          </span>
                  </dt>
        <dd class="inherited">
          Creates a new stream with each data event of this stream asynchronously
mapped to a new event. <a href="dart-async/Stream/asyncMap.html">[...]</a>
                  <div class="features">inherited</div>
</dd>
        <dt id="cast" class="callable inherited">
          <span class="name"><a href="dart-async/Stream/cast.html">cast</a></span><span class="signature">&lt;<wbr><span class="type-parameter">R</span>&gt;</span><span class="signature">(<wbr>)
            <span class="returntype parameter">&#8594; <a href="dart-async/Stream-class.html">Stream</a><span class="signature">&lt;<wbr><span class="type-parameter">R</span>&gt;</span></span>
          </span>
                  </dt>
        <dd class="inherited">
          Adapt this stream to be a <code>Stream&lt;R&gt;</code>. <a href="dart-async/Stream/cast.html">[...]</a>
                  <div class="features">inherited</div>
</dd>
        <dt id="contains" class="callable inherited">
          <span class="name"><a href="dart-async/Stream/contains.html">contains</a></span><span class="signature">(<wbr><span class="parameter" id="contains-param-needle"><span class="type-annotation"><a href="dart-core/Object-class.html">Object</a></span> <span class="parameter-name">needle</span></span>)
            <span class="returntype parameter">&#8594; <a href="dart-async/Future-class.html">Future</a><span class="signature">&lt;<wbr><span class="type-parameter"><a href="dart-core/bool-class.html">bool</a></span>&gt;</span></span>
          </span>
                  </dt>
        <dd class="inherited">
          Returns whether <code>needle</code> occurs in the elements provided by this stream. <a href="dart-async/Stream/contains.html">[...]</a>
                  <div class="features">inherited</div>
</dd>
        <dt id="distinct" class="callable inherited">
          <span class="name"><a href="dart-async/Stream/distinct.html">distinct</a></span><span class="signature">(<wbr>[<span class="parameter" id="distinct-param-equals"><span class="type-annotation"><a href="dart-core/bool-class.html">bool</a></span> <span class="parameter-name">equals</span>(<span class="parameter" id="equals-param-previous"><span class="type-annotation">T</span> <span class="parameter-name">previous</span>, </span> <span class="parameter" id="equals-param-next"><span class="type-annotation">T</span> <span class="parameter-name">next</span></span>)</span> ])
            <span class="returntype parameter">&#8594; <a href="dart-async/Stream-class.html">Stream</a><span class="signature">&lt;<wbr><span class="type-parameter"><a href="dart-io/HttpRequest-class.html">HttpRequest</a></span>&gt;</span></span>
          </span>
                  </dt>
        <dd class="inherited">
          Skips data events if they are equal to the previous data event. <a href="dart-async/Stream/distinct.html">[...]</a>
                  <div class="features">inherited</div>
</dd>
        <dt id="drain" class="callable inherited">
          <span class="name"><a href="dart-async/Stream/drain.html">drain</a></span><span class="signature">&lt;<wbr><span class="type-parameter">E</span>&gt;</span><span class="signature">(<wbr>[<span class="parameter" id="drain-param-futureValue"><span class="type-annotation">E</span> <span class="parameter-name">futureValue</span></span> ])
            <span class="returntype parameter">&#8594; <a href="dart-async/Future-class.html">Future</a><span class="signature">&lt;<wbr><span class="type-parameter">E</span>&gt;</span></span>
          </span>
                  </dt>
        <dd class="inherited">
          Discards all data on this stream, but signals when it is done or an error
occurred. <a href="dart-async/Stream/drain.html">[...]</a>
                  <div class="features">inherited</div>
</dd>
        <dt id="elementAt" class="callable inherited">
          <span class="name"><a href="dart-async/Stream/elementAt.html">elementAt</a></span><span class="signature">(<wbr><span class="parameter" id="elementAt-param-index"><span class="type-annotation"><a href="dart-core/int-class.html">int</a></span> <span class="parameter-name">index</span></span>)
            <span class="returntype parameter">&#8594; <a href="dart-async/Future-class.html">Future</a><span class="signature">&lt;<wbr><span class="type-parameter"><a href="dart-io/HttpRequest-class.html">HttpRequest</a></span>&gt;</span></span>
          </span>
                  </dt>
        <dd class="inherited">
          Returns the value of the <code>index</code>th data event of this stream. <a href="dart-async/Stream/elementAt.html">[...]</a>
                  <div class="features">inherited</div>
</dd>
        <dt id="every" class="callable inherited">
          <span class="name"><a href="dart-async/Stream/every.html">every</a></span><span class="signature">(<wbr><span class="parameter" id="every-param-test"><span class="type-annotation"><a href="dart-core/bool-class.html">bool</a></span> <span class="parameter-name">test</span>(<span class="parameter" id="test-param-element"><span class="type-annotation">T</span> <span class="parameter-name">element</span></span>)</span>)
            <span class="returntype parameter">&#8594; <a href="dart-async/Future-class.html">Future</a><span class="signature">&lt;<wbr><span class="type-parameter"><a href="dart-core/bool-class.html">bool</a></span>&gt;</span></span>
          </span>
                  </dt>
        <dd class="inherited">
          Checks whether <code>test</code> accepts all elements provided by this stream. <a href="dart-async/Stream/every.html">[...]</a>
                  <div class="features">inherited</div>
</dd>
        <dt id="expand" class="callable inherited">
          <span class="name"><a href="dart-async/Stream/expand.html">expand</a></span><span class="signature">&lt;<wbr><span class="type-parameter">S</span>&gt;</span><span class="signature">(<wbr><span class="parameter" id="expand-param-convert"><span class="type-annotation"><a href="dart-core/Iterable-class.html">Iterable</a><span class="signature">&lt;<wbr><span class="type-parameter">S</span>&gt;</span></span> <span class="parameter-name">convert</span>(<span class="parameter" id="convert-param-element"><span class="type-annotation">T</span> <span class="parameter-name">element</span></span>)</span>)
            <span class="returntype parameter">&#8594; <a href="dart-async/Stream-class.html">Stream</a><span class="signature">&lt;<wbr><span class="type-parameter">S</span>&gt;</span></span>
          </span>
                  </dt>
        <dd class="inherited">
          Transforms each element of this stream into a sequence of elements. <a href="dart-async/Stream/expand.html">[...]</a>
                  <div class="features">inherited</div>
</dd>
        <dt id="firstWhere" class="callable inherited">
          <span class="name"><a href="dart-async/Stream/firstWhere.html">firstWhere</a></span><span class="signature">(<wbr><span class="parameter" id="firstWhere-param-test"><span class="type-annotation"><a href="dart-core/bool-class.html">bool</a></span> <span class="parameter-name">test</span>(<span class="parameter" id="test-param-element"><span class="type-annotation">T</span> <span class="parameter-name">element</span></span>), {</span> <span class="parameter" id="firstWhere-param-orElse"><span class="type-annotation"><a href="dart-io/HttpRequest-class.html">HttpRequest</a></span> <span class="parameter-name">orElse</span>()</span> })
            <span class="returntype parameter">&#8594; <a href="dart-async/Future-class.html">Future</a><span class="signature">&lt;<wbr><span class="type-parameter"><a href="dart-io/HttpRequest-class.html">HttpRequest</a></span>&gt;</span></span>
          </span>
                  </dt>
        <dd class="inherited">
          Finds the first element of this stream matching <code>test</code>. <a href="dart-async/Stream/firstWhere.html">[...]</a>
                  <div class="features">inherited</div>
</dd>
        <dt id="fold" class="callable inherited">
          <span class="name"><a href="dart-async/Stream/fold.html">fold</a></span><span class="signature">&lt;<wbr><span class="type-parameter">S</span>&gt;</span><span class="signature">(<wbr><span class="parameter" id="fold-param-initialValue"><span class="type-annotation">S</span> <span class="parameter-name">initialValue</span>, </span> <span class="parameter" id="fold-param-combine"><span class="type-annotation">S</span> <span class="parameter-name">combine</span>(<span class="parameter" id="combine-param-previous"><span class="type-annotation">S</span> <span class="parameter-name">previous</span>, </span> <span class="parameter" id="combine-param-element"><span class="type-annotation">T</span> <span class="parameter-name">element</span></span>)</span>)
            <span class="returntype parameter">&#8594; <a href="dart-async/Future-class.html">Future</a><span class="signature">&lt;<wbr><span class="type-parameter">S</span>&gt;</span></span>
          </span>
                  </dt>
        <dd class="inherited">
          Combines a sequence of values by repeatedly applying <code>combine</code>. <a href="dart-async/Stream/fold.html">[...]</a>
                  <div class="features">inherited</div>
</dd>
        <dt id="forEach" class="callable inherited">
          <span class="name"><a href="dart-async/Stream/forEach.html">forEach</a></span><span class="signature">(<wbr><span class="parameter" id="forEach-param-action"><span class="type-annotation">void</span> <span class="parameter-name">action</span>(<span class="parameter" id="action-param-element"><span class="type-annotation">T</span> <span class="parameter-name">element</span></span>)</span>)
            <span class="returntype parameter">&#8594; <a href="dart-async/Future-class.html">Future</a></span>
          </span>
                  </dt>
        <dd class="inherited">
          Executes <code>action</code> on each element of this stream. <a href="dart-async/Stream/forEach.html">[...]</a>
                  <div class="features">inherited</div>
</dd>
        <dt id="handleError" class="callable inherited">
          <span class="name"><a href="dart-async/Stream/handleError.html">handleError</a></span><span class="signature">(<wbr><span class="parameter" id="handleError-param-onError"><span class="type-annotation"><a href="dart-core/Function-class.html">Function</a></span> <span class="parameter-name">onError</span>, {</span> <span class="parameter" id="handleError-param-test"><span class="type-annotation"><a href="dart-core/bool-class.html">bool</a></span> <span class="parameter-name">test</span>(<span class="parameter" id="test-param-error"><span class="type-annotation">dynamic</span> <span class="parameter-name">error</span></span>)</span> })
            <span class="returntype parameter">&#8594; <a href="dart-async/Stream-class.html">Stream</a><span class="signature">&lt;<wbr><span class="type-parameter"><a href="dart-io/HttpRequest-class.html">HttpRequest</a></span>&gt;</span></span>
          </span>
                  </dt>
        <dd class="inherited">
          Creates a wrapper Stream that intercepts some errors from this stream. <a href="dart-async/Stream/handleError.html">[...]</a>
                  <div class="features">inherited</div>
</dd>
        <dt id="join" class="callable inherited">
          <span class="name"><a href="dart-async/Stream/join.html">join</a></span><span class="signature">(<wbr>[<span class="parameter" id="join-param-separator"><span class="type-annotation"><a href="dart-core/String-class.html">String</a></span> <span class="parameter-name">separator</span> = <span class="default-value">""</span></span> ])
            <span class="returntype parameter">&#8594; <a href="dart-async/Future-class.html">Future</a><span class="signature">&lt;<wbr><span class="type-parameter"><a href="dart-core/String-class.html">String</a></span>&gt;</span></span>
          </span>
                  </dt>
        <dd class="inherited">
          Combines the string representation of elements into a single string. <a href="dart-async/Stream/join.html">[...]</a>
                  <div class="features">inherited</div>
</dd>
        <dt id="lastWhere" class="callable inherited">
          <span class="name"><a href="dart-async/Stream/lastWhere.html">lastWhere</a></span><span class="signature">(<wbr><span class="parameter" id="lastWhere-param-test"><span class="type-annotation"><a href="dart-core/bool-class.html">bool</a></span> <span class="parameter-name">test</span>(<span class="parameter" id="test-param-element"><span class="type-annotation">T</span> <span class="parameter-name">element</span></span>), {</span> <span class="parameter" id="lastWhere-param-orElse"><span class="type-annotation"><a href="dart-io/HttpRequest-class.html">HttpRequest</a></span> <span class="parameter-name">orElse</span>()</span> })
            <span class="returntype parameter">&#8594; <a href="dart-async/Future-class.html">Future</a><span class="signature">&lt;<wbr><span class="type-parameter"><a href="dart-io/HttpRequest-class.html">HttpRequest</a></span>&gt;</span></span>
          </span>
                  </dt>
        <dd class="inherited">
          Finds the last element in this stream matching <code>test</code>. <a href="dart-async/Stream/lastWhere.html">[...]</a>
                  <div class="features">inherited</div>
</dd>
        <dt id="listen" class="callable inherited">
          <span class="name"><a href="dart-async/Stream/listen.html">listen</a></span><span class="signature">(<wbr><span class="parameter" id="listen-param-onData"><span class="type-annotation">void</span> <span class="parameter-name">onData</span>(<span class="parameter" id="onData-param-event"><span class="type-annotation">T</span> <span class="parameter-name">event</span></span>), {</span> <span class="parameter" id="listen-param-onError"><span class="type-annotation"><a href="dart-core/Function-class.html">Function</a></span> <span class="parameter-name">onError</span>, </span> <span class="parameter" id="listen-param-onDone"><span class="type-annotation">void</span> <span class="parameter-name">onDone</span>(), </span> <span class="parameter" id="listen-param-cancelOnError"><span class="type-annotation"><a href="dart-core/bool-class.html">bool</a></span> <span class="parameter-name">cancelOnError</span></span> })
            <span class="returntype parameter">&#8594; <a href="dart-async/StreamSubscription-class.html">StreamSubscription</a><span class="signature">&lt;<wbr><span class="type-parameter"><a href="dart-io/HttpRequest-class.html">HttpRequest</a></span>&gt;</span></span>
          </span>
                  </dt>
        <dd class="inherited">
          Adds a subscription to this stream. <a href="dart-async/Stream/listen.html">[...]</a>
                  <div class="features">inherited</div>
</dd>
        <dt id="map" class="callable inherited">
          <span class="name"><a href="dart-async/Stream/map.html">map</a></span><span class="signature">&lt;<wbr><span class="type-parameter">S</span>&gt;</span><span class="signature">(<wbr><span class="parameter" id="map-param-convert"><span class="type-annotation">S</span> <span class="parameter-name">convert</span>(<span class="parameter" id="convert-param-event"><span class="type-annotation">T</span> <span class="parameter-name">event</span></span>)</span>)
            <span class="returntype parameter">&#8594; <a href="dart-async/Stream-class.html">Stream</a><span class="signature">&lt;<wbr><span class="type-parameter">S</span>&gt;</span></span>
          </span>
                  </dt>
        <dd class="inherited">
          Transforms each element of this stream into a new stream event. <a href="dart-async/Stream/map.html">[...]</a>
                  <div class="features">inherited</div>
</dd>
        <dt id="noSuchMethod" class="callable inherited">
          <span class="name"><a href="dart-core/Object/noSuchMethod.html">noSuchMethod</a></span><span class="signature">(<wbr><span class="parameter" id="noSuchMethod-param-invocation"><span class="type-annotation"><a href="dart-core/Invocation-class.html">Invocation</a></span> <span class="parameter-name">invocation</span></span>)
            <span class="returntype parameter">&#8594; dynamic</span>
          </span>
                  </dt>
        <dd class="inherited">
          Invoked when a non-existent method or property is accessed. <a href="dart-core/Object/noSuchMethod.html">[...]</a>
                  <div class="features">inherited</div>
</dd>
        <dt id="pipe" class="callable inherited">
          <span class="name"><a href="dart-async/Stream/pipe.html">pipe</a></span><span class="signature">(<wbr><span class="parameter" id="pipe-param-streamConsumer"><span class="type-annotation"><a href="dart-async/StreamConsumer-class.html">StreamConsumer</a><span class="signature">&lt;<wbr><span class="type-parameter"><a href="dart-io/HttpRequest-class.html">HttpRequest</a></span>&gt;</span></span> <span class="parameter-name">streamConsumer</span></span>)
            <span class="returntype parameter">&#8594; <a href="dart-async/Future-class.html">Future</a></span>
          </span>
                  </dt>
        <dd class="inherited">
          Pipes the events of this stream into <code>streamConsumer</code>. <a href="dart-async/Stream/pipe.html">[...]</a>
                  <div class="features">inherited</div>
</dd>
        <dt id="reduce" class="callable inherited">
          <span class="name"><a href="dart-async/Stream/reduce.html">reduce</a></span><span class="signature">(<wbr><span class="parameter" id="reduce-param-combine"><span class="type-annotation"><a href="dart-io/HttpRequest-class.html">HttpRequest</a></span> <span class="parameter-name">combine</span>(<span class="parameter" id="combine-param-previous"><span class="type-annotation">T</span> <span class="parameter-name">previous</span>, </span> <span class="parameter" id="combine-param-element"><span class="type-annotation">T</span> <span class="parameter-name">element</span></span>)</span>)
            <span class="returntype parameter">&#8594; <a href="dart-async/Future-class.html">Future</a><span class="signature">&lt;<wbr><span class="type-parameter"><a href="dart-io/HttpRequest-class.html">HttpRequest</a></span>&gt;</span></span>
          </span>
                  </dt>
        <dd class="inherited">
          Combines a sequence of values by repeatedly applying <code>combine</code>. <a href="dart-async/Stream/reduce.html">[...]</a>
                  <div class="features">inherited</div>
</dd>
        <dt id="singleWhere" class="callable inherited">
          <span class="name"><a href="dart-async/Stream/singleWhere.html">singleWhere</a></span><span class="signature">(<wbr><span class="parameter" id="singleWhere-param-test"><span class="type-annotation"><a href="dart-core/bool-class.html">bool</a></span> <span class="parameter-name">test</span>(<span class="parameter" id="test-param-element"><span class="type-annotation">T</span> <span class="parameter-name">element</span></span>), {</span> <span class="parameter" id="singleWhere-param-orElse"><span class="type-annotation"><a href="dart-io/HttpRequest-class.html">HttpRequest</a></span> <span class="parameter-name">orElse</span>()</span> })
            <span class="returntype parameter">&#8594; <a href="dart-async/Future-class.html">Future</a><span class="signature">&lt;<wbr><span class="type-parameter"><a href="dart-io/HttpRequest-class.html">HttpRequest</a></span>&gt;</span></span>
          </span>
                  </dt>
        <dd class="inherited">
          Finds the single element in this stream matching <code>test</code>. <a href="dart-async/Stream/singleWhere.html">[...]</a>
                  <div class="features">inherited</div>
</dd>
        <dt id="skip" class="callable inherited">
          <span class="name"><a href="dart-async/Stream/skip.html">skip</a></span><span class="signature">(<wbr><span class="parameter" id="skip-param-count"><span class="type-annotation"><a href="dart-core/int-class.html">int</a></span> <span class="parameter-name">count</span></span>)
            <span class="returntype parameter">&#8594; <a href="dart-async/Stream-class.html">Stream</a><span class="signature">&lt;<wbr><span class="type-parameter"><a href="dart-io/HttpRequest-class.html">HttpRequest</a></span>&gt;</span></span>
          </span>
                  </dt>
        <dd class="inherited">
          Skips the first <code>count</code> data events from this stream. <a href="dart-async/Stream/skip.html">[...]</a>
                  <div class="features">inherited</div>
</dd>
        <dt id="skipWhile" class="callable inherited">
          <span class="name"><a href="dart-async/Stream/skipWhile.html">skipWhile</a></span><span class="signature">(<wbr><span class="parameter" id="skipWhile-param-test"><span class="type-annotation"><a href="dart-core/bool-class.html">bool</a></span> <span class="parameter-name">test</span>(<span class="parameter" id="test-param-element"><span class="type-annotation">T</span> <span class="parameter-name">element</span></span>)</span>)
            <span class="returntype parameter">&#8594; <a href="dart-async/Stream-class.html">Stream</a><span class="signature">&lt;<wbr><span class="type-parameter"><a href="dart-io/HttpRequest-class.html">HttpRequest</a></span>&gt;</span></span>
          </span>
                  </dt>
        <dd class="inherited">
          Skip data events from this stream while they are matched by <code>test</code>. <a href="dart-async/Stream/skipWhile.html">[...]</a>
                  <div class="features">inherited</div>
</dd>
        <dt id="take" class="callable inherited">
          <span class="name"><a href="dart-async/Stream/take.html">take</a></span><span class="signature">(<wbr><span class="parameter" id="take-param-count"><span class="type-annotation"><a href="dart-core/int-class.html">int</a></span> <span class="parameter-name">count</span></span>)
            <span class="returntype parameter">&#8594; <a href="dart-async/Stream-class.html">Stream</a><span class="signature">&lt;<wbr><span class="type-parameter"><a href="dart-io/HttpRequest-class.html">HttpRequest</a></span>&gt;</span></span>
          </span>
                  </dt>
        <dd class="inherited">
          Provides at most the first <code>count</code> data events of this stream. <a href="dart-async/Stream/take.html">[...]</a>
                  <div class="features">inherited</div>
</dd>
        <dt id="takeWhile" class="callable inherited">
          <span class="name"><a href="dart-async/Stream/takeWhile.html">takeWhile</a></span><span class="signature">(<wbr><span class="parameter" id="takeWhile-param-test"><span class="type-annotation"><a href="dart-core/bool-class.html">bool</a></span> <span class="parameter-name">test</span>(<span class="parameter" id="test-param-element"><span class="type-annotation">T</span> <span class="parameter-name">element</span></span>)</span>)
            <span class="returntype parameter">&#8594; <a href="dart-async/Stream-class.html">Stream</a><span class="signature">&lt;<wbr><span class="type-parameter"><a href="dart-io/HttpRequest-class.html">HttpRequest</a></span>&gt;</span></span>
          </span>
                  </dt>
        <dd class="inherited">
          Forwards data events while <code>test</code> is successful. <a href="dart-async/Stream/takeWhile.html">[...]</a>
                  <div class="features">inherited</div>
</dd>
        <dt id="timeout" class="callable inherited">
          <span class="name"><a href="dart-async/Stream/timeout.html">timeout</a></span><span class="signature">(<wbr><span class="parameter" id="timeout-param-timeLimit"><span class="type-annotation"><a href="dart-core/Duration-class.html">Duration</a></span> <span class="parameter-name">timeLimit</span>, {</span> <span class="parameter" id="timeout-param-onTimeout"><span class="type-annotation">void</span> <span class="parameter-name">onTimeout</span>(<span class="parameter" id="onTimeout-param-sink"><span class="type-annotation"><a href="dart-async/EventSink-class.html">EventSink</a><span class="signature">&lt;<wbr><span class="type-parameter">T</span>&gt;</span></span> <span class="parameter-name">sink</span></span>)</span> })
            <span class="returntype parameter">&#8594; <a href="dart-async/Stream-class.html">Stream</a><span class="signature">&lt;<wbr><span class="type-parameter"><a href="dart-io/HttpRequest-class.html">HttpRequest</a></span>&gt;</span></span>
          </span>
                  </dt>
        <dd class="inherited">
          Creates a new stream with the same events as this stream. <a href="dart-async/Stream/timeout.html">[...]</a>
                  <div class="features">inherited</div>
</dd>
        <dt id="toList" class="callable inherited">
          <span class="name"><a href="dart-async/Stream/toList.html">toList</a></span><span class="signature">(<wbr>)
            <span class="returntype parameter">&#8594; <a href="dart-async/Future-class.html">Future</a><span class="signature">&lt;<wbr><span class="type-parameter"><a href="dart-core/List-class.html">List</a><span class="signature">&lt;<wbr><span class="type-parameter"><a href="dart-io/HttpRequest-class.html">HttpRequest</a></span>&gt;</span></span>&gt;</span></span>
          </span>
                  </dt>
        <dd class="inherited">
          Collects all elements of this stream in a <a href="dart-core/List-class.html">List</a>. <a href="dart-async/Stream/toList.html">[...]</a>
                  <div class="features">inherited</div>
</dd>
        <dt id="toSet" class="callable inherited">
          <span class="name"><a href="dart-async/Stream/toSet.html">toSet</a></span><span class="signature">(<wbr>)
            <span class="returntype parameter">&#8594; <a href="dart-async/Future-class.html">Future</a><span class="signature">&lt;<wbr><span class="type-parameter"><a href="dart-core/Set-class.html">Set</a><span class="signature">&lt;<wbr><span class="type-parameter"><a href="dart-io/HttpRequest-class.html">HttpRequest</a></span>&gt;</span></span>&gt;</span></span>
          </span>
                  </dt>
        <dd class="inherited">
          Collects the data of this stream in a <a href="dart-core/Set-class.html">Set</a>. <a href="dart-async/Stream/toSet.html">[...]</a>
                  <div class="features">inherited</div>
</dd>
        <dt id="toString" class="callable inherited">
          <span class="name"><a href="dart-core/Object/toString.html">toString</a></span><span class="signature">(<wbr>)
            <span class="returntype parameter">&#8594; <a href="dart-core/String-class.html">String</a></span>
          </span>
                  </dt>
        <dd class="inherited">
          Returns a string representation of this object.
                  <div class="features">inherited</div>
</dd>
        <dt id="transform" class="callable inherited">
          <span class="name"><a href="dart-async/Stream/transform.html">transform</a></span><span class="signature">&lt;<wbr><span class="type-parameter">S</span>&gt;</span><span class="signature">(<wbr><span class="parameter" id="transform-param-streamTransformer"><span class="type-annotation"><a href="dart-async/StreamTransformer-class.html">StreamTransformer</a><span class="signature">&lt;<wbr><span class="type-parameter"><a href="dart-io/HttpRequest-class.html">HttpRequest</a></span>, <span class="type-parameter">S</span>&gt;</span></span> <span class="parameter-name">streamTransformer</span></span>)
            <span class="returntype parameter">&#8594; <a href="dart-async/Stream-class.html">Stream</a><span class="signature">&lt;<wbr><span class="type-parameter">S</span>&gt;</span></span>
          </span>
                  </dt>
        <dd class="inherited">
          Applies  <code>streamTransformer</code> to this stream. <a href="dart-async/Stream/transform.html">[...]</a>
                  <div class="features">inherited</div>
</dd>
        <dt id="where" class="callable inherited">
          <span class="name"><a href="dart-async/Stream/where.html">where</a></span><span class="signature">(<wbr><span class="parameter" id="where-param-test"><span class="type-annotation"><a href="dart-core/bool-class.html">bool</a></span> <span class="parameter-name">test</span>(<span class="parameter" id="test-param-event"><span class="type-annotation">T</span> <span class="parameter-name">event</span></span>)</span>)
            <span class="returntype parameter">&#8594; <a href="dart-async/Stream-class.html">Stream</a><span class="signature">&lt;<wbr><span class="type-parameter"><a href="dart-io/HttpRequest-class.html">HttpRequest</a></span>&gt;</span></span>
          </span>
                  </dt>
        <dd class="inherited">
          Creates a new stream from this stream that discards some elements. <a href="dart-async/Stream/where.html">[...]</a>
                  <div class="features">inherited</div>
</dd>
      </dl>
    </section>

    <section class="summary offset-anchor inherited" id="operators">
      <h2>Operators</h2>
      <dl class="callables">
        <dt id="operator ==" class="callable inherited">
          <span class="name"><a href="dart-core/Object/operator_equals.html">operator ==</a></span><span class="signature">(<wbr><span class="parameter" id="==-param-other"><span class="type-annotation">dynamic</span> <span class="parameter-name">other</span></span>)
            <span class="returntype parameter">&#8594; <a href="dart-core/bool-class.html">bool</a></span>
          </span>
                  </dt>
        <dd class="inherited">
          The equality operator. <a href="dart-core/Object/operator_equals.html">[...]</a>
                  <div class="features">inherited</div>
</dd>
      </dl>
    </section>


    <section class="summary offset-anchor" id="static-methods">
      <h2>Static Methods</h2>
      <dl class="callables">
        <dt id="bind" class="callable">
          <span class="name"><a href="dart-io/HttpServer/bind.html">bind</a></span><span class="signature">(<wbr><span class="parameter" id="bind-param-address"><span class="type-annotation">dynamic</span> <span class="parameter-name">address</span>, </span> <span class="parameter" id="bind-param-port"><span class="type-annotation"><a href="dart-core/int-class.html">int</a></span> <span class="parameter-name">port</span>, {</span> <span class="parameter" id="bind-param-backlog"><span class="type-annotation"><a href="dart-core/int-class.html">int</a></span> <span class="parameter-name">backlog</span>: <span class="default-value">0</span>, </span> <span class="parameter" id="bind-param-v6Only"><span class="type-annotation"><a href="dart-core/bool-class.html">bool</a></span> <span class="parameter-name">v6Only</span>: <span class="default-value">false</span>, </span> <span class="parameter" id="bind-param-shared"><span class="type-annotation"><a href="dart-core/bool-class.html">bool</a></span> <span class="parameter-name">shared</span>: <span class="default-value">false</span></span> })
            <span class="returntype parameter">&#8594; <a href="dart-async/Future-class.html">Future</a><span class="signature">&lt;<wbr><span class="type-parameter"><a href="dart-io/HttpServer-class.html">HttpServer</a></span>&gt;</span></span>
          </span>
                  </dt>
        <dd>
          Starts listening for HTTP requests on the specified <code>address</code> and
<code>port</code>. <a href="dart-io/HttpServer/bind.html">[...]</a>
                  
</dd>
        <dt id="bindSecure" class="callable">
          <span class="name"><a href="dart-io/HttpServer/bindSecure.html">bindSecure</a></span><span class="signature">(<wbr><span class="parameter" id="bindSecure-param-address"><span class="type-annotation">dynamic</span> <span class="parameter-name">address</span>, </span> <span class="parameter" id="bindSecure-param-port"><span class="type-annotation"><a href="dart-core/int-class.html">int</a></span> <span class="parameter-name">port</span>, </span> <span class="parameter" id="bindSecure-param-context"><span class="type-annotation"><a href="dart-io/SecurityContext-class.html">SecurityContext</a></span> <span class="parameter-name">context</span>, {</span> <span class="parameter" id="bindSecure-param-backlog"><span class="type-annotation"><a href="dart-core/int-class.html">int</a></span> <span class="parameter-name">backlog</span>: <span class="default-value">0</span>, </span> <span class="parameter" id="bindSecure-param-v6Only"><span class="type-annotation"><a href="dart-core/bool-class.html">bool</a></span> <span class="parameter-name">v6Only</span>: <span class="default-value">false</span>, </span> <span class="parameter" id="bindSecure-param-requestClientCertificate"><span class="type-annotation"><a href="dart-core/bool-class.html">bool</a></span> <span class="parameter-name">requestClientCertificate</span>: <span class="default-value">false</span>, </span> <span class="parameter" id="bindSecure-param-shared"><span class="type-annotation"><a href="dart-core/bool-class.html">bool</a></span> <span class="parameter-name">shared</span>: <span class="default-value">false</span></span> })
            <span class="returntype parameter">&#8594; <a href="dart-async/Future-class.html">Future</a><span class="signature">&lt;<wbr><span class="type-parameter"><a href="dart-io/HttpServer-class.html">HttpServer</a></span>&gt;</span></span>
          </span>
                  </dt>
        <dd>
          The <code>address</code> can either be a <a href="dart-core/String-class.html">String</a> or an
<a href="dart-io/InternetAddress-class.html">InternetAddress</a>. If <code>address</code> is a <a href="dart-core/String-class.html">String</a>, <a href="dart-io/HttpServer/bind.html">bind</a> will
perform a <a href="dart-io/InternetAddress/lookup.html">InternetAddress.lookup</a> and use the first value in the
list. To listen on the loopback adapter, which will allow only
incoming connections from the local host, use the value
<a href="dart-io/InternetAddress/loopbackIPv4.html">InternetAddress.loopbackIPv4</a> or
<a href="dart-io/InternetAddress/loopbackIPv6.html">InternetAddress.loopbackIPv6</a>. To allow for incoming
connection from the network use either one of the values
<a href="dart-io/InternetAddress/anyIPv4.html">InternetAddress.anyIPv4</a> or <a href="dart-io/InternetAddress/anyIPv6.html">InternetAddress.anyIPv6</a> to
bind to all interfaces or the IP address of a specific interface. <a href="dart-io/HttpServer/bindSecure.html">[...]</a>
                  
</dd>
      </dl>
    </section>


  </div> <!-- /.main-content -->

  <div id="dartdoc-sidebar-right" class="col-xs-6 col-sm-6 col-md-2 sidebar sidebar-offcanvas-right">
    <ol>
      <li class="section-title"><a href="dart-io/HttpServer-class.html#constructors">Constructors</a></li>
      <li><a href="dart-io/HttpServer/HttpServer.listenOn.html">listenOn</a></li>
    
      <li class="section-title">
        <a href="dart-io/HttpServer-class.html#instance-properties">Properties</a>
      </li>
      <li><a href="dart-io/HttpServer/address.html">address</a></li>
      <li><a href="dart-io/HttpServer/autoCompress.html">autoCompress</a></li>
      <li><a href="dart-io/HttpServer/defaultResponseHeaders.html">defaultResponseHeaders</a></li>
      <li><a href="dart-io/HttpServer/idleTimeout.html">idleTimeout</a></li>
      <li><a href="dart-io/HttpServer/port.html">port</a></li>
      <li><a href="dart-io/HttpServer/serverHeader.html">serverHeader</a></li>
      <li><a href="dart-io/HttpServer/sessionTimeout.html">sessionTimeout</a></li>
      <li class="inherited"><a href="dart-async/Stream/first.html">first</a></li>
      <li class="inherited"><a href="dart-core/Object/hashCode.html">hashCode</a></li>
      <li class="inherited"><a href="dart-async/Stream/isBroadcast.html">isBroadcast</a></li>
      <li class="inherited"><a href="dart-async/Stream/isEmpty.html">isEmpty</a></li>
      <li class="inherited"><a href="dart-async/Stream/last.html">last</a></li>
      <li class="inherited"><a href="dart-async/Stream/length.html">length</a></li>
      <li class="inherited"><a href="dart-core/Object/runtimeType.html">runtimeType</a></li>
      <li class="inherited"><a href="dart-async/Stream/single.html">single</a></li>
    
      <li class="section-title"><a href="dart-io/HttpServer-class.html#instance-methods">Methods</a></li>
      <li><a href="dart-io/HttpServer/close.html">close</a></li>
      <li><a href="dart-io/HttpServer/connectionsInfo.html">connectionsInfo</a></li>
      <li class="inherited"><a href="dart-async/Stream/any.html">any</a></li>
      <li class="inherited"><a href="dart-async/Stream/asBroadcastStream.html">asBroadcastStream</a></li>
      <li class="inherited"><a href="dart-async/Stream/asyncExpand.html">asyncExpand</a></li>
      <li class="inherited"><a href="dart-async/Stream/asyncMap.html">asyncMap</a></li>
      <li class="inherited"><a href="dart-async/Stream/cast.html">cast</a></li>
      <li class="inherited"><a href="dart-async/Stream/contains.html">contains</a></li>
      <li class="inherited"><a href="dart-async/Stream/distinct.html">distinct</a></li>
      <li class="inherited"><a href="dart-async/Stream/drain.html">drain</a></li>
      <li class="inherited"><a href="dart-async/Stream/elementAt.html">elementAt</a></li>
      <li class="inherited"><a href="dart-async/Stream/every.html">every</a></li>
      <li class="inherited"><a href="dart-async/Stream/expand.html">expand</a></li>
      <li class="inherited"><a href="dart-async/Stream/firstWhere.html">firstWhere</a></li>
      <li class="inherited"><a href="dart-async/Stream/fold.html">fold</a></li>
      <li class="inherited"><a href="dart-async/Stream/forEach.html">forEach</a></li>
      <li class="inherited"><a href="dart-async/Stream/handleError.html">handleError</a></li>
      <li class="inherited"><a href="dart-async/Stream/join.html">join</a></li>
      <li class="inherited"><a href="dart-async/Stream/lastWhere.html">lastWhere</a></li>
      <li class="inherited"><a href="dart-async/Stream/listen.html">listen</a></li>
      <li class="inherited"><a href="dart-async/Stream/map.html">map</a></li>
      <li class="inherited"><a href="dart-core/Object/noSuchMethod.html">noSuchMethod</a></li>
      <li class="inherited"><a href="dart-async/Stream/pipe.html">pipe</a></li>
      <li class="inherited"><a href="dart-async/Stream/reduce.html">reduce</a></li>
      <li class="inherited"><a href="dart-async/Stream/singleWhere.html">singleWhere</a></li>
      <li class="inherited"><a href="dart-async/Stream/skip.html">skip</a></li>
      <li class="inherited"><a href="dart-async/Stream/skipWhile.html">skipWhile</a></li>
      <li class="inherited"><a href="dart-async/Stream/take.html">take</a></li>
      <li class="inherited"><a href="dart-async/Stream/takeWhile.html">takeWhile</a></li>
      <li class="inherited"><a href="dart-async/Stream/timeout.html">timeout</a></li>
      <li class="inherited"><a href="dart-async/Stream/toList.html">toList</a></li>
      <li class="inherited"><a href="dart-async/Stream/toSet.html">toSet</a></li>
      <li class="inherited"><a href="dart-core/Object/toString.html">toString</a></li>
      <li class="inherited"><a href="dart-async/Stream/transform.html">transform</a></li>
      <li class="inherited"><a href="dart-async/Stream/where.html">where</a></li>
    
      <li class="section-title inherited"><a href="dart-io/HttpServer-class.html#operators">Operators</a></li>
      <li class="inherited"><a href="dart-core/Object/operator_equals.html">operator ==</a></li>
    
    
      <li class="section-title"><a href="dart-io/HttpServer-class.html#static-methods">Static methods</a></li>
      <li><a href="dart-io/HttpServer/bind.html">bind</a></li>
      <li><a href="dart-io/HttpServer/bindSecure.html">bindSecure</a></li>
    
    </ol>
  </div><!--/.sidebar-offcanvas-->

</main>

<footer>
  <span class="no-break">
    shake 0.1.0
  </span>

  
</footer>

<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script>
<script src="static-assets/typeahead.bundle.min.js"></script>
<script src="static-assets/highlight.pack.js"></script>
<script src="static-assets/URI.js"></script>
<script src="static-assets/script.js"></script>


</body>

</html>
